package com.liug.droidsmall2.fragment;

import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.support.v7.widget.GridLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import com.liug.droidsmall2.R;
import com.liug.droidsmall2.adapter.HomeTabAdapter;

/**
 * Created by LG on 2018/10/11.
 */

public class ThreeFragment extends Fragment{

    @Nullable
    @Override
    public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
        View view = View.inflate(getActivity(), R.layout.home_one_frag, null);
        RecyclerView recy_one = (RecyclerView) view.findViewById(R.id.recy_one);
        recy_one.setLayoutManager(new GridLayoutManager(getActivity(),5));
        HomeTabAdapter homeTabAdapter = new HomeTabAdapter(getActivity());
        recy_one.setAdapter(homeTabAdapter);
        return view;
    }
}
